﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace PIM_ATE
{
    public partial class FrmResult : Form
    {
        public FrmResult()
        {
            InitializeComponent();
        }

        private void FrmResult_Load(object sender, EventArgs e)
        {
            var resultObj = new ClsDataResultForAntennaBuilder(GDefine.DBNamePIM);
            string[] lstName = resultObj.getProcodeListFromTMO();
            if (lstName != null)
            {
                cbProcode.Items.AddRange(lstName);
            }
        }

        private void button1_Click(object sender, EventArgs e)
        {
            ClsDataConfigBase cfgObj = new ClsDataConfigBase(GDefine.DBNamePIM);
            if (cfgObj.constructByProcode(cbProcode.Text).Length == 0)
            {
                this.DialogResult = DialogResult.OK;
            }
            else
            {
                MessageBox.Show("该名称已配置");
            }
        }
    }
}
